home *** CD-ROM | disk | FTP | other *** search
/ Otherware / Otherware_1_SB_Development.iso / mac / util / comm / arapp144.sit / Practical 14400FXSA 1.0 next >
Encoding:
Text File  |  1992-08-06  |  5.1 KB  |  255 lines

  1. ! "Practical Peripherals PM14400FXSA - 8/6/92"
  2. !  by SBM  CompuServe ID: 72711,2044 (daily) or 74435,357 (occasional)
  3. !          GENIE: S.MEUSE2 (occasional)
  4. !          AppleLink: CYTYC.DEV (daily)
  5. !          Internet: 72711.2044@compuserve.com
  6. !
  7. ! Non-commercial distribution of non-beta versions is encouraged provided
  8. ! the files are unmodified and all files are included in the distribution.
  9. ! Please report any problems.  Thanks!
  10. !
  11. ! This script REQUIRES a hardware handshaking cable.  Practical Peripherals
  12. ! and MacConnection sell ones known to work correctly.
  13. !
  14. ! revision history
  15. ! 1.0B1- 5/8/92-
  16. !    Initial beta release. Uploaded to CompuServe's PPIFORUM only.
  17. ! 1.0B2- 6/23/92-
  18. !    Not released. Local testing only.
  19. !    Ñ Fixed bug where script wasn't respecting the modem's CS line.
  20. !    Ñ Looking into bugs reported with this script at both ends @ 14400bps.
  21. !      I did duplicate this, and it appears to be due to an acknowledged
  22. !      incompatibility between ARA 1.0 and Apple Internet Router 2.0.
  23. ! 1.0B3- 7/6/92-
  24. !    Released via email to a few beta sites for testing only.
  25. ! 1.0B4- 7/10/92-
  26. !    Second general beta release. Uploaded to CompuServe's PPIFORUM only.
  27. ! 1.0B5- 7/28/92-
  28. !    local testing only.  Wait 90 seconds after dial for carrier.
  29. ! 1.0- 8/6/92-
  30. !    Initial general release.  Uploaded to PPIFORUM, MACCOM, GEnie, & the PPI BBS.
  31. !
  32. @ORIGINATE
  33. @ANSWER
  34. !
  35. @LABEL 1
  36. serreset 19200, 0, 8, 1
  37. !
  38. ! first recall the factory configuration
  39. !
  40. matchclr
  41. settries 0
  42. matchstr 1 3 "OK\13\10"
  43. @LABEL 2
  44. write "AT&F\13"
  45. matchread 30
  46. inctries
  47. iftries 2 59
  48. jump 2
  49. !
  50. ! then echo off, DTR off, enable the modem's RTS/CTS flow control
  51. @LABEL 3
  52. matchclr
  53. matchstr 1 4 "OK\13\10"
  54. write "ATE0&C1&D0&K3\13"
  55. matchread 30
  56. jump 59
  57. !
  58. ! then turn off error correction, use autospeed buffering,
  59. ! configure CONNECT messages to report DCE speed instead of DTE
  60. ! allow 90 seconds for a successful connection (up from 50).
  61. !
  62. @LABEL 4
  63. matchclr
  64. matchstr 1 5 "OK\13\10"
  65. matchstr 2 5 "ERROR\13\10"
  66. write "AT&Q6W2S7=90\13"
  67. matchread 30
  68. !
  69. ! If speaker on flag is true, jump to label 8.  Else turn off the speaker
  70. @LABEL 5
  71. ifstr 2 8 "1"
  72. matchclr
  73. matchstr 1 8 "OK\13\10"
  74. write "ATM0\13"
  75. matchread 30
  76. jump 59
  77. !
  78. ! The modem is ready.  So enable answering, or originate a call
  79. !
  80. @LABEL 8
  81. ifANSWER 30
  82. note "Dialing ^1" 3
  83. write "ATS0=0DT^1\13"
  84. !
  85. @LABEL 9
  86. matchclr
  87. matchstr  1 11 "CONNECT 1200\13\10"
  88. matchstr  2 12 "CONNECT 2400\13\10"
  89. matchstr  3 13 "CONNECT 4800\13\10"
  90. matchstr  4 14 "CONNECT 7200\13\10"
  91. matchstr  5 15 "CONNECT 9600\13\10"
  92. matchstr  6 16 "CONNECT 12000\13\10"
  93. matchstr  7 17 "CONNECT 14400\13\10"
  94. matchstr  8 18 "CONNECT 19200\13\10"
  95. matchstr  9 50 "NO CARRIER\13\10"
  96. matchstr 10 50 "ERROR\13\10"
  97. matchstr 11 52 "NO DIALTONE\13\10"
  98. matchstr 12 53 "BUSY\13\10"
  99. matchstr 13 54 "NO ANSWER\13\10"
  100. matchread 999
  101. jump 59
  102. !
  103. @LABEL 11
  104. note "Communicating at 1200 bps." 2
  105. CommunicatingAt 1200
  106. jump 19
  107. !
  108. @LABEL 12
  109. note "Communicating at 2400 bps." 2
  110. CommunicatingAt 2400
  111. jump 19
  112. !
  113. @LABEL 13
  114. note "Communicating at 4800 bps." 2
  115. CommunicatingAt 4800
  116. jump 19
  117. !
  118. @LABEL 14
  119. note "Communicating at 7200 bps." 2
  120. CommunicatingAt 7200
  121. jump 19
  122. !
  123. @LABEL 15
  124. note "Communicating at 9600 bps." 2
  125. CommunicatingAt 9600
  126. jump 19
  127. !
  128. @LABEL 16
  129. note "Communicating at 12 kbps." 2
  130. CommunicatingAt 12000
  131. jump 19
  132. !
  133. @LABEL 17
  134. note "Communicating at 14.4 kbps." 2
  135. CommunicatingAt 14400
  136. jump 19
  137. !
  138. @LABEL 18
  139. note "Communicating at 19.2 kbps." 2
  140. CommunicatingAt 19200
  141. !
  142. ! enable RTS/CTS handshaking at the serial port
  143. !
  144. @LABEL 19
  145. HSReset 0 1 0 0 0 0
  146. ifANSWER 20
  147. pause 30
  148. @LABEL 20
  149. exit 0
  150. !
  151. ! @ANSWER
  152. ! Set up modem to answer
  153. @LABEL 30
  154. matchclr
  155. matchstr 1 31 "OK\13\10"
  156. write "ATS0=1\13"
  157. matchread 30
  158. jump 59
  159. !
  160. @LABEL 31
  161. matchclr
  162. matchstr  1 32 "RING\13\10"
  163. matchstr  2 11 "CONNECT 1200\13\10"
  164. matchstr  3 12 "CONNECT 2400\13\10"
  165. matchstr  4 13 "CONNECT 4800\13\10"
  166. matchstr  5 14 "CONNECT 7200\13\10"
  167. matchstr  6 15 "CONNECT 9600\13\10"
  168. matchstr  7 16 "CONNECT 12000\13\10"
  169. matchstr  8 17 "CONNECT 14400\13\10"
  170. matchstr  9 18 "CONNECT 19200\13\10"
  171. matchstr 10 50 "NO CARRIER\13\10"
  172. matchstr 11 50 "ERROR\13\10"
  173. matchstr 12 52 "NO DIALTONE\13\10"
  174. matchstr 13 53 "BUSY\13\10"
  175. matchstr 14 54 "NO ANSWER\13\10"
  176. matchread 700
  177. jump 31
  178. !
  179. @LABEL 32
  180. userhook 1
  181. note "Answering phone╔" 2
  182. jump 31
  183. !
  184. ! 50: error messages
  185. !
  186. @LABEL 50
  187. exit -6021
  188. !
  189. @LABEL 52
  190. exit -6020
  191. !
  192. @LABEL 53
  193. exit -6022
  194. !
  195. @LABEL 54
  196. exit -6023
  197. !
  198. @LABEL 59
  199. exit -6019
  200. !
  201. ! turn off RTS/CTS at serial port, hang up the modem
  202. !
  203. @HANGUP
  204. @LABEL 60
  205. HSReset 0 0 0 0 0 0
  206. settries 0
  207. @LABEL 61
  208. matchclr
  209. matchstr 1 64 "OK\13\10"
  210. matchstr 2 63 "NO CARRIER\13\10"
  211. matchstr 3 64 "ERROR\13\10"
  212. write "ATH0\13"
  213. matchread 15
  214. inctries
  215. iftries 3 64
  216. ! no response, try escape sequence
  217. matchclr
  218. matchstr 1 62 "OK\13\10"
  219. matchstr 2 63 "NO CARRIER\13\10"
  220. write "+++"
  221. matchread 18
  222. ! No response from modem, try reset command
  223. write "ATZ\13"
  224. pause 30
  225. jump 61
  226. !
  227. @LABEL 62
  228. matchclr
  229. matchstr 1 64 "OK\13\10"
  230. matchstr 2 63 "NO CARRIER\13\10"
  231. write "ATH0\13"
  232. matchread 50
  233. jump 61
  234. !
  235. @LABEL 63
  236. pause 45
  237. flush
  238. !
  239. ! recall the factory settings
  240. !
  241. @LABEL 64
  242. matchclr
  243. matchstr 1 65 "OK\13\10"
  244. write "AT&F\13"
  245. matchread 30
  246. !
  247. @LABEL 65
  248. matchclr
  249. matchstr 1 66 "OK\13\10"
  250. write "ATS0=0\13"
  251. matchread 30
  252. !
  253. @LABEL 66
  254. exit 0
  255.